<?php include('header.php');


if($_GET['action']=="save"){
		$exec="insert into shuliang (number) values ('".$_POST['number']."')";
		$result=mysql_query($exec) or die(mysql_error());
		mysql_close();
		echo"<script>alert('Add successfully! ');window.location.href='apply_list.php';</script>"; 
}
?>
<script language=javascript>
<!--
function check()
{
 if (form1.number.value=="")
 {
 alert("Please input number!");
 form1.number.focus();
 return(false);
 }
}

//-->
</script><style type="text/css">
<!--
body {
	background-color: #E1E1E1;
}
body,td,th {
	color: #000000;
	font-family: Trebuchet MS;
}
-->
</style>
<div id="wapper" style="width:980px;margin:0 auto">
  <table width="99%" border="0" cellpadding="0" cellspacing="0" class="CContent">
    <tr>
      <td class="CPanel"><table width="95%" border="0" align="center" cellpadding="0" cellspacing="0">
      		 <tr height="50" class="CTitle" >
                <td height="22" colspan="10" align="center" style="font-size:16px">Booking quantity (<a href="apply_list.php">Apply List</a>)</td>
            </tr>
          <tr>
            <td height="40" class="font42">
                <form name="form1" method="post"  action="?action=save" onsubmit="return check()">
                <table width="100%" border="0" cellspacing="0" bordercolor="#733E3F">
                  <tr height="40">
                    <td width="19%" align="right" valign="middle">Number:&nbsp;</td>
                    <td width="81%">&nbsp;
                      <input name="number" type="text" id="number" value="" style="width:220px;" />
                      </td>
                  </tr>
                  <tr height="40">
                  	<td align="right"></td>
                    <td><input type="submit" name="submit1" value="Submit" style="border:1px solid #CCC;" /> </td>
                  </tr>
                </table>
            </form>
              </td>
          </tr>
        </table></td>
    </tr>
    <tr>
      <td class="CPanel"></td>
    </tr>
  </TABLE>
</div>
</form>
<?php include('footer.php')?>